home *** CD-ROM | disk | FTP | other *** search
- /* $VER: ScanBrush.rexx 1.1 for DPAINT V5.0 by Jochen Grus (02.09.96) */
-
- OPTIONS RESULTS
-
- ADDRESS "DPAINT.1"
-
- call SCAN() /* Scans the image into a temporary file */
- call IMPORTGRAPHIC() /* Loads Image into DPAINT */
- call DELETEFILE() /* Removes temporary image file */
-
- EXIT
-
- SCAN:
- /* Scans the image into a temporary file using the program "ScanToDisk". */
- if not 1=open('path','ENV:ScanQuix/Path','READ') then do
- ok=0
- return
- end
-
- pragma('DIRECTORY',READLN('path'))
- address command 'ScanQuix3/ScanToDisk FILE=ram:1 TRUECOLOR NOICONS NOGUI'
- if RC>=5 then do
- ok=0
- return
- end
-
- return
-
-
-
- IMPORTGRAPHIC:
- /* Loads the image into DPAINT */
- if ok=0 then
- return
-
- 'LOADbrush ram:1'
- return
-
-
-
- DELETEFILE:
- /* removes temporary file */
- address command 'delete ram:1'
-
-
- return
-
-